package com.cn.learn.creator.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.View;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.Map;

/**
 * @ClassName RouteController
 * @Description
 * @Author JiJiang
 * @Date 2023/7/8 21:59
 * @Version 1.0
 */
@Controller
public class RouteController {
    @RequestMapping
    public String gotoIndexPage() {
        return "index";
    }


    @RequestMapping("/test")
    public String gotoTestPage(@RequestParam(value = "haha", required = false) String haha) {
        System.out.println("haha ==" + haha);
        return "test/test";
    }
}
